<template>
	<el-form ref="form" :model="form" label-width="160rpx">
		<el-form-item label="选择产品">
			<el-select v-model="form.product" placeholder="请选择产品">
				<el-option label="尿不湿NB" value="1"></el-option>
				<el-option label="尿不湿L" value="2"></el-option>
			</el-select>
		</el-form-item>
		<el-form-item label="选择批次">
			<el-select v-model="form.batch" placeholder="请选择批次">
				<el-option label="20201010111211123" value="1"></el-option>
				<el-option label="20201010111211124" value="2"></el-option>
			</el-select>
		</el-form-item>
		<el-form-item label="库存数量">
			100件
		</el-form-item>
		<el-form-item label="报损数量">
			<el-input v-model="form.num"></el-input>
		</el-form-item>
		<el-form-item label="报损原因">
			<el-select v-model="form.Reasons" placeholder="请选择报损原因">
				<el-option label="区域一" value="shanghai"></el-option>
				<el-option label="区域二" value="beijing"></el-option>
			</el-select>
		</el-form-item>
		<el-form-item label="报损图片">
			<u-upload ref="uUpload" :action="action" :auto-upload="false"></u-upload>
		</el-form-item>
		<el-form-item>
			<el-button class="submit" type="primary" @click="onSubmit">立即创建</el-button>
		</el-form-item>
	</el-form>
</template>

<script>
	export default {
		data() {
			return {
				action: '',
				form: {
					num: '',
					product: '',
					batch: '',
					Reasons: '',
					region: '',
					type: [],
					action: 'http://www.example.com/upload',
				},
			}
		},
		methods: {
			onSubmit() {
				uni.navigateTo({
					url:'./checkingIndex'
				})
			}
		}
	}
</script>

<style scoped lang="scss">
	.el-form-item__content{
		margin: 0;
	}
	.el-button--primary {
		position: relative;
		bottom: -200rpx;
		left: 110rpx;
		width: 224rpx;
		height: 60rpx;
		color: rgba(80, 80, 80, 1);
		background-color: rgba(255, 255, 255, 1);
		box-shadow: rgba(128, 128, 128, 1) solid 1px;
		border-radius: 10rpx;
		font-size: 28rpx;
		line-height: 0rpx;
		border: 2rpx solid #000000;
		text-align: center;
	}
</style>
